<script setup>
import { ref } from 'vue';

  const msg = ref('侬好呀，类好呀')
  const showAlert = ref(()=>{
    alert('侬好呀,类好呀111')
  })

  defineExpose({
    msg,
    showAlert
  })
</script>
  
<template>
  <div>我是子组件{{ msg }}</div> 
</template>
  
<style scoped>
  
</style>